/* $Id: ServiceRoleDAO.java 
 * Copyright (C) 2011, TRAKHEES
 *  
 * Revision History
 *
 * Date  			Author 		    	Remarks
 * ---------------------------------------------------------------------------------
 *
 */
package ae.pcfc.etks.online.common.dao;

import java.util.List;

import ae.pcfc.etks.online.common.domain.Client;
import ae.pcfc.etks.online.common.domain.ClientServiceRole;
import ae.pcfc.etks.online.common.domain.ServiceRole;

public interface ServiceRoleDAO {
	
	/**
	 * findServiceRoleByRoleIds
	 * Method to find the list of service role domain objects by service role ids
	 * @param serviceRoleIds
	 * @return
	 * List<ServiceRole>
	 */
	public List<ServiceRole> findServiceRoleByRoleIds(List<Long> serviceRoleIds);
	
	/**
	 * findServiceRoleByRoleId
	 * Method to find the service role domain object list by role id
	 * @param roleId
	 * @return
	 * List<ServiceRole>
	 */
	public List<ServiceRole> findServiceRoleByRoleId(Long roleId);
	
	/**
	 * add
	 * Method to add the service role domain object to the database
	 * @param serviceRole
	 * void
	 */
	public void add(ServiceRole serviceRole);

	/**
	 * findServiceRolesByServiceType
	 * Method to find the service roles by service type - Internal/External
	 * @param serviceType
	 * @return
	 * List<ServiceRole>
	 */
	public List<ServiceRole> findServiceRolesByServiceType(String serviceType);

	/**
	 * findServiceRolesByUserName
	 * Method to find the service roles associated to an user by username
	 * @param strUserName
	 * @return
	 * List<ServiceRole>
	 */
	public List<ServiceRole> findServiceRolesByUserName(String strUserName);
	/**
	 * findServiceRoleByClientAndRoleId
	 * Method to find the service roles associated to a client and role id
	 * @param Client
	 * @param	roleid
	 * @return
	 * List<ServiceRole>
	 */
	public List<ClientServiceRole> findServiceRoleByClientAndRoleId(Client client, Long roleId);

	public List<ServiceRole> findAvailableServiceRoleByRoleIdForClient(Long roleId, Client client);
}
